import React, { Component } from 'react';

class List extends Component {
  // props 
  static defaultProps =  {
    title: '天气不错'
  }
  render() {
    const { mes, title, handleSetMes } = this.props
    return (
      <div>
         <h1>我是list 组件</h1>
         <h2>{ mes }</h2>
         <h3>{ title }</h3>
         <button onClick={ handleSetMes }>修改mes</button>
      </div>
    );
  }
}

export default List;
